package top.xcxdl.rural.mapper;

import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import top.xcxdl.rural.entity.RuralProduct;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;

import java.util.List;

/**
 * <p>
 *  Mapper 接口
 * </p>
 *
 * @author Ding
 * @since 2022-05-06
 */
@Mapper
public interface RuralProductMapper extends BaseMapper<RuralProduct> {

    List<RuralProduct> getList(@Param("productStatus") Integer productStatus,@Param("productType") Integer productType,@Param("authorType") Integer authorType,@Param("key") String key);

    List<RuralProduct> getProductListByUser(@Param("key") String key);

    RuralProduct getDetail(@Param("productId") Integer productId);

    List<RuralProduct> getProductListByUserId(@Param("authorId") Integer authorId,@Param("authorType") Integer authorType,@Param("key") String key);
}
